load("@batfish//skylark:junit.bzl", "junit_tests")
load("@batfish//skylark:pmd_test.bzl", "pmd_test")
load("@rules_java//java:defs.bzl", "java_library")

package(
    default_testonly = True,
    default_visibility = ["//visibility:public"],
)

java_library(
    name = "identifiers",
    srcs = glob(
        ["*.java"],
        exclude = ["*Test.java"],
    ),
    deps = ["//projects/batfish-common-protocol:common"],
)

pmd_test(
    name = "pmd",
    lib = ":identifiers",
)

junit_tests(
    name = "tests",
    srcs = glob(
        ["*.java"],
        allow_empty = True,
        exclude = ["Test*.java"],
    ),
    deps = ["@maven//:junit_junit"],
)
